package com.kingstar.ceres.entity.secondary;


import lombok.Builder;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;
import lombok.ToString;
import lombok.experimental.Tolerate;

import java.util.Date;
import java.io.Serializable;
import java.math.BigDecimal;

/**
 * IRS市场成交行情表
 *
 * @author 傻男人
 * @since 2022-03-30
 */

@Data
@ToString(callSuper = true)
@TableName(value = "k_cmds_irs_market_deal")
@Builder
public class KCmdsIrsMarketDeal implements Serializable {

    private static final long serialVersionUID = 1L;

    @Tolerate
    public KCmdsIrsMarketDeal() {
    }

    /**
     * 成交编号
     */
	@TableField("exec_id")
	private String execId;
    /**
     * 成交类型
     */
	@TableField("exec_type")
	private String execType;
    /**
     * 名义本金金额，单位：元
     */
	@TableField("last_qty")
	private BigDecimal lastQty;
    /**
     * 交易品种代码
     */
	@TableField("security_id")
	private String securityId;
    /**
     * 交易品种名称
     */
	private String symbol;
    /**
     * 成交日期
     */
	@TableField("trade_date")
	private String tradeDate;
    /**
     * 成交时间
     */
	@TableField("trade_time")
	private String tradeTime;
    /**
     * 报文生成时间
     */
	@TableField("transact_time")
	private String transactTime;
    /**
     * 市场标识
     */
	@TableField("market_indicator")
	private String marketIndicator;
    /**
     * 交易期限
     */
	@TableField("trade_limit_dayes")
	private String tradeLimitDayes;
    /**
     * 交易类型
     */
	private String side;
    /**
     * 固定利率
     */
	@TableField("fix_rate")
	private BigDecimal fixRate;
    /**
     * 浮动利率曲线名称
     */
	@TableField("float_benchmark_curvename")
	private String floatBenchmarkCurvename;
    /**
     * 利差
     */
	@TableField("benchmark_spread")
	private BigDecimal benchmarkSpread;
    /**
     * 创建时间
     */
	@TableField(value = "create_time", fill = FieldFill.INSERT)
	private Long createTime;
    /**
     * 来源
     */
	@TableField("message_source")
	private String messageSource;
    /**
     * 浮动买卖方向
     */
	@TableField("float_side")
	private String floatSide;
    /**
     * 固定买卖方向
     */
	@TableField("fix_side")
	private String fixSide;
    /**
     * 成交时间（时间戳）
     */
	@TableField("quotation_time")
	private Long quotationTime;

	public class Meta {
        public static final String EXEC_ID = "exec_id";
        public static final String EXEC_TYPE = "exec_type";
        public static final String LAST_QTY = "last_qty";
        public static final String SECURITY_ID = "security_id";
        public static final String SYMBOL = "symbol";
        public static final String TRADE_DATE = "trade_date";
        public static final String TRADE_TIME = "trade_time";
        public static final String TRANSACT_TIME = "transact_time";
        public static final String MARKET_INDICATOR = "market_indicator";
        public static final String TRADE_LIMIT_DAYES = "trade_limit_dayes";
        public static final String SIDE = "side";
        public static final String FIX_RATE = "fix_rate";
        public static final String FLOAT_BENCHMARK_CURVENAME = "float_benchmark_curvename";
        public static final String BENCHMARK_SPREAD = "benchmark_spread";
        public static final String CREATE_TIME = "create_time";
        public static final String MESSAGE_SOURCE = "message_source";
        public static final String FLOAT_SIDE = "float_side";
        public static final String FIX_SIDE = "fix_side";
        public static final String QUOTATION_TIME = "quotation_time";
    }
}